package com.ruoyi.order.domain;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.domain.BaseEntity;
import com.ruoyi.employee.domain.EmployeeUser;
import com.ruoyi.market.domain.ConfigBase;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import java.math.BigDecimal;
import java.util.Date;

/**
 * PK订单 tb_order_pk
 * 
 * @author ruoyi
 */
public class OrderPk extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 订单编号 */
    private String orderNo;

    /** 发起店员等级ID */
    private Long startLevelId;

    /** 接受店员等级ID */
    private Long acceptLevelId;

    /** 发起店员ID */
    private Long startUserId;

    /** 接受店员ID */
    private Long acceptUserId;

    /** 店铺Id */
    private String shopId;

    /** 应用Id */
    private String appId;

    /** PK开始时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date pkStartTime;

    /** PK结束时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date pkEndTime;

    /** PK时长 单位：小时 */
    private int pkTime;

    /** 是否大厅可见（Y=是,N=否, 未知） */
    private String isAvailable;

    /** 是否已结算（Y=是,N=否, 未知） */
    private String isSettle;

    /** 准备中（未开始，匹配中）-preparing 进行中-going 成功完成-success 失败-failure 已取消-cancel */
    private String pkStatus;

    /** 发起用户完成金额 */
    private BigDecimal startUserAmount;

    /** 发起用户获取奖励门槛金额 */
    private BigDecimal startUserThreshold;

    /** 接受用户完成金额 */
    private BigDecimal acceptUserAmount;

    /** 接受用户获取奖励门槛金额 */
    private BigDecimal acceptUserThreshold;

    /** 用户完成总金额 - 用来前台排序 */
    private BigDecimal totalUserAmount;

    /** 删除标志（0代表存在 2代表删除） */
    private String delFlag;

    private EmployeeUser startUserInfo;

    private EmployeeUser acceptUserInfo;

    /** 所属店铺信息   */
    private ConfigBase shopInfo;

    public OrderPk()
    {

    }

    public OrderPk(String orderNo)
    {
        this.orderNo = orderNo;
    }

    public String getOrderNo(){ return orderNo; }

    public void setOrderNo(String orderNo){ this.orderNo = orderNo; }

    public BigDecimal getStartUserAmount(){ return startUserAmount;}

    public void setStartUserAmount(BigDecimal startUserAmount){ this.startUserAmount = startUserAmount; }

    public BigDecimal getStartUserThreshold(){ return startUserThreshold;}

    public void setStartUserThreshold(BigDecimal startUserThreshold){ this.startUserThreshold = startUserThreshold; }


    public BigDecimal getAcceptUserAmount(){ return acceptUserAmount;}

    public void setAcceptUserAmount(BigDecimal acceptUserAmount){ this.acceptUserAmount = acceptUserAmount; }

    public BigDecimal getAcceptUserThreshold(){ return acceptUserThreshold;}

    public void setAcceptUserThreshold(BigDecimal acceptUserThreshold){ this.acceptUserThreshold = acceptUserThreshold; }

    public BigDecimal getTotalUserAmount(){ return totalUserAmount;}

    public void setTotalUserAmount(BigDecimal totalUserAmount){ this.totalUserAmount = totalUserAmount; }

    public Long getAcceptUserId(){ return acceptUserId;}

    public void setAcceptUserId(Long acceptUserId)
    {
        this.acceptUserId = acceptUserId;
    }

    public int getPkTime()
    {
        return pkTime;
    }

    public void setPkTime(int pkTime)
    {
        this.pkTime = pkTime;
    }

    public Long getStartLevelId()
    {
        return startLevelId;
    }

    public void setStartLevelId(Long startLevelId)
    {
        this.startLevelId = startLevelId;
    }

    public Long getAcceptLevelId()
    {
        return acceptLevelId;
    }

    public void setAcceptLevelId(Long acceptLevelId)
    {
        this.acceptLevelId = acceptLevelId;
    }



    public Long getStartUserId()
    {
        return startUserId;
    }

    public void setStartUserId(Long startUserId)
    {
        this.startUserId = startUserId;
    }
    public String getAppId()
    {
        return appId;
    }

    public void setAppId(String appId)
    {
        this.appId = appId;
    }

    public String getShopId()
    {
        return shopId;
    }

    public void setShopId(String shopId)
    {
        this.shopId = shopId;
    }

    public String getIsAvailable()
    {
        return isAvailable;
    }

    public void setIsAvailable(String isAvailable)
    {
        this.isAvailable = isAvailable;
    }

    public String getIsSettle()
    {
        return isSettle;
    }

    public void setIsSettle(String isSettle)
    {
        this.isSettle = isSettle;
    }

    public String getPkStatus()
    {
        return pkStatus;
    }

    public void setPkStatus(String pkStatus)
    {
        this.pkStatus = pkStatus;
    }

    public Date getPkStartTime()
    {
        return pkStartTime;
    }

    public void setPkStartTime(Date pkStartTime)
    {
        this.pkStartTime = pkStartTime;
    }

    public Date getPkEndTime()
    {
        return pkEndTime;
    }

    public void setPkEndTime(Date pkEndTime)
    {
        this.pkEndTime = pkEndTime;
    }

    public EmployeeUser getStartUserInfo() { return startUserInfo; }

    public void setStartUserInfo(EmployeeUser startUserInfo)
    {
        this.startUserInfo = startUserInfo;
    }

    public EmployeeUser getAcceptUserInfo() { return acceptUserInfo; }

    public void setAcceptUserInfo(EmployeeUser acceptUserInfo)
    {
        this.acceptUserInfo = acceptUserInfo;
    }

    public ConfigBase getShopInfo()
    {
        return shopInfo;
    }

    public void setShopInfo(ConfigBase shopInfo)
    {
        this.shopInfo = shopInfo;
    }

    public String getDelFlag()
    {
        return delFlag;
    }

    public void setDelFlag(String delFlag)
    {
        this.delFlag = delFlag;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("orderNo", getOrderNo())
            .append("startLevelId", getStartLevelId())
            .append("acceptLevelId", getAcceptLevelId())
            .append("startUserId", getStartUserId())
            .append("pkTime", getPkTime())
            .append("acceptUserId", getAcceptUserId())
            .append("appId", getAppId())
            .append("shopId", getShopId())
            .append("isAvailable", getIsAvailable())
            .append("isSettle", getIsSettle())
            .append("pkStatus", getPkStatus())
            .append("startUserAmount", getStartUserAmount())
            .append("startUserThreshold", getStartUserThreshold())
            .append("acceptUserAmount", getAcceptUserAmount())
            .append("acceptUserThreshold", getAcceptUserThreshold())
            .append("totalUserAmount", getTotalUserAmount())
            .append("appId", getAppId())
            .append("pkStartTime", getPkStartTime())
            .append("pkEndTime", getPkEndTime())
            .append("shopInfo", getShopInfo())
            .append("startUserInfo", getStartUserInfo())
            .append("acceptUserInfo", getAcceptUserInfo())
            .append("delFlag", getDelFlag())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .append("remark", getRemark())
            .toString();
    }
}
